using Godot;

[Tool]
[GlobalClass]
public partial class VoxFormatLoader : ResourceFormatLoader
{
    public override Variant _Load(string path, string originalPath, bool useSubThreads, int cacheMode)
    {
        return VoxModel.Load(path);
    }

    public override string[] _GetRecognizedExtensions() => ["vox"];

    public override bool _HandlesType(StringName type) => ClassDB.IsParentClass(type, "Resource");

    public override string _GetResourceType(string path) => "Resource";
}
